
import './dialog.css'
export const Dialog = (props)=>{

    const onOk=()=>{
        //确定的业务逻辑
        props.setVisible('hidden')
    }
    const onCancel=()=>{
        //取消的业务逻辑
        props.setVisible('hidden')
    }
    return (
        <div>
            <div  className={`container-box ${props.visible}`}>
            <div className='container'>
                <div className="box" >
                <h1>{props.title}</h1>
                <h1>{props.content}</h1>
                <h1>{props.footer}</h1>
                <div className="buttonBox"><div onClick={() => onOk()} className="Ok">确定</div> <div onClick={() => onCancel()} className="Concel">取消</div></div>
                </div>
            </div>  
            </div>
        </div>
    )
}